package com.example.demo01.controller;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class HelloController {

    @Value("${test.hello:TEST}")
    private String testHello;

    @GetMapping("/hello")
    public String hello(){
          return "hello World!" + testHello;
      }

      @PostMapping("/hello/post")
      public String helloPost(String name){
        return "Hello World! Post," + name;
      }
}
